Automatic stiffness prosthesis